/**
 * 
 */
package com.sims.action.bbs;

import org.springframework.beans.factory.annotation.Autowired;

import com.sims.bean.Theme;
import com.sims.service.BBSService;
import com.sims.util.ActionEnhanced;
import com.sims.util.Constant;

/**
 * @author Administrator
 *
 */
public class DeleteThemeAction extends ActionEnhanced {
	private Theme theme;
	@Autowired
	private BBSService bbsService;
	
	
	public Theme getTheme() {
		return theme;
	}


	public void setTheme(Theme theme) {
		this.theme = theme;
	}


	@Override
	public String execute() {
		
		result = bbsService.deleteTheme(theme);
		if (result.containsKey(Constant.SUCCESS)) {
			System.out.println("success");
			return SUCCESS;
		}
		return ERROR;
	}
}
